<?php
// No direct access
defined('_JEXEC') or die;

$item = $this->item;
?>

<div id="article-detail">
	<h1><?php echo $item->title; ?></h1>
	
	<div class="description">
		<?php echo $item->fulltext; ?>
	</div>
	
	<?php if(!empty($this->otherContents)): ?>
	<h1>Bài viết liên quan</h1>
	<div class="other-contents">
		<ul>
			<?php foreach ($this->otherContents as $content): ?>
			<li>
				<a href="<?php echo JRoute::_(JE_ContentHelperRoute::getArticleRoute($content->id, $content->catid, $content->alias)); ?>">
					&bull; <?php echo $content->title; ?>
				</a>
			</li>
			<?php endforeach; ?>
		</ul>
	</div>
	<?php endif; ?>
	
	<?php 
		$jeComments = JPATH_SITE . DS . 'components' . DS . 'com_je_comment' . DS . 'je_comment.php';
	
		if(file_exists($jeComments))
		{
			require_once $jeComments;
			Je_Comment::display(JRequest::getVar('id'), 'com_je_content', $item->title);
		}
	?>
</div>
